package cn.com.nes.site.controller.contract.vo;

import cn.com.nes.site.entity.vo.BaseVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.Date;

@Data
@ApiModel(value = "合同保存入参模型")
public class ContractSaveVO extends BaseVO {

    @ApiModelProperty(value = "合同UUID",required = true)
    private String contractUuid;

    @ApiModelProperty(value = "合同名称")
    @NotBlank(message = "合同名称", groups = {Save.class, Update.class})
    private String contractName;

    @ApiModelProperty(value = "合同编码")
    @NotBlank(message = "合同编码", groups = {Save.class})
    private String contractNumber;

    @ApiModelProperty(value = "合同类型")
    @NotNull(message = "合同类型", groups = {Save.class, Update.class})
    private Integer contractType;

    @ApiModelProperty(value = "客户UUID")
    @NotBlank(message = "客户UUID", groups = {Save.class, Update.class})
    private String customerUuid;

    @ApiModelProperty(value = "客户户名称")
    @NotBlank(message = "客户名称", groups = {Save.class, Update.class})
    private String customerName;

    @ApiModelProperty(value = "销售单ID")
    @NotNull(message = "销售单ID", groups = {Save.class, Update.class})
    private Long saleOderId;

    @ApiModelProperty(value = "合同金额")
    @NotNull(message = "合同金额", groups = {Save.class, Update.class})
    private BigDecimal contractAmount;

    @ApiModelProperty(value = "生效日期")
    @NotNull(message = "生效日期", groups = {Save.class, Update.class})
    private Date effectiveDate;

    @ApiModelProperty(value = "终止日期")
    @NotNull(message = "终止日期", groups = {Save.class, Update.class})
    private Date terminationDate;

    @ApiModelProperty("文件名称")
    @NotBlank(message = "文件名称", groups = {Save.class, Update.class})
    private String fileName;

    @ApiModelProperty("文件路径")
    @NotBlank(message = "文件路径", groups = {Save.class, Update.class})
    private String ossPath;

}
